ACPI, APEI: Add apei_exec_run_optional
authorHuang Ying <ying.huang@intel.com>
Fri, 22 Mar 2013 11:46:25 +0000 (12:46 +0100)
committerJan Beulich <jbeulich@suse.com>
Fri, 22 Mar 2013 11:46:25 +0000 (12:46 +0100)
commit72af01bf6f7489e54ad59270222a29d3e8c501d1
treefdb768cfed7e54fc0b6ab3c773e83fb61c448804
parent0611689d9153227831979c7bafe594214b8505a3
ACPI, APEI: Add apei_exec_run_optional

Some actions in APEI ERST and EINJ tables are optional, for example,
ACPI_EINJ_BEGIN_OPERATION action is used to do some preparation for
error injection, and firmware may choose to do nothing here.  While
some other actions are mandatory, for example, firmware must provide
ACPI_EINJ_GET_ERROR_TYPE implementation.

Original implementation treats all actions as optional (that is, can
have no instructions), that may cause issue if firmware does not
provide some mandatory actions.  To fix this, this patch adds
apei_exec_run_optional, which should be used for optional actions.
The original apei_exec_run should be used for mandatory actions.

Signed-off-by: Huang Ying <ying.huang@intel.com>
Signed-off-by: Jan Beulich <jbeulich@suse.com>
Tested-by: Andrew Cooper <andrew.cooper3@citrix.com>
xen/drivers/acpi/apei/apei-base.c
xen/drivers/acpi/apei/apei-internal.h